Creation of Solid Geometry Surface Models for 3D-Printing, Shape Optimization, Topology Optimization (PDE-Toolbox), and Dynamic Simulation (Simscape Multi-Body)
Part B - Solid Geometry Manipulation
Tim Lueth - Professor at Technical Universiity of Munich - Germany - 2019
Set Java Heap to 2048 MByte
3 Creation and Manipulation of Solid Geometries
3.1 Predefined Solid Geometries
3.1.1 Predefined Spheres and Ellipsoids
SGofCPLcommand(
'sph 10'
);
SGofCPLcommand('sph 10')
SGofCPLcommand(
'sph 10 45'
);
SGofCPLcommand('sph 10 45')
SGofCPLcommand(
'sph 10 45 20 '
);
SGofCPLcommand('sph 10 45 20')
SGofCPLcommand(
'sph 10 45 20 30'
);
SGofCPLcommand('sph 10 45 20 30')
3.1.2
Predefined Solid - Screws, Nuts, Thread Cutter
SGofCPLcommand(
'scr 5 10'
);
SGofCPLcommand('scr 5 10')
SGofCPLcommand(
'scr -5 10 10'
);
SGofCPLcommand('scr -5 10 10')
SGofCPLcommand(
'scr -5 10'
);
SGofCPLcommand('scr -5 10')
3.1.3
Predefined Solid – Letters and Strings
SGofCPLcommand(
'text Hello'
);
SGofCPLcommand('text Hello')
SGofCPLcommand(
'text Hello 100'
);
SGofCPLcommand('text Hello 100')
SGofCPLcommand(
'text Hello 100 50'
);
SGofCPLcommand('text Hello 100 50')
3.2
Manipulating Solid Geometries (SG)
3.2.1 Manipulating Solids – Chamfer Edges
SGofCPLcommand(
'b 10 10, c 4 3, h 4'
);
SGofCPLcommand('b 10 10, c 4 3, h 4')
SGofCPLcommand(
'b 10 10, c 4 3, h 4, cham 1'
);
VLradialEdges: Radius 1.50 reduced to 1.08 VLradialEdges: Radius 1.50 reduced to 1.08
SGofCPLcommand('b 10 10, c 4 3, h 4, cham 1')
SGofCPLcommand(
'b 10 10, c 4 3, h 4, cham 1 0.5'
);
VLradialEdges: Radius 1.50 reduced to 1.08 VLradialEdges: Radius 1.50 reduced to 1.08
SGofCPLcommand('b 10 10, c 4 3, h 4, cham 1 0.5')
3.2.2
Manipulating Solids – Move in Space
SGofCPLcommand(
'sph 30 90 20 10,'
);
SGofCPLcommand('sph 30 90 20 10')
SGofCPLcommand(
'sph 30 90 20 10, move 10 20'
);
SGofCPLcommand('sph 30 90 20 10, move 10 20')
3.2.3
Manipulating Solids – Rotate Solids
SGofCPLcommand(
'b 20 10, move 5 20, b 10 40, h 4'
);
SGofCPLcommand('b 20 10, move 5 20, b 10 40, h 4')
SGofCPLcommand(
'b 20 10, move 5 20, b 10 40, h 4, rotx 90'
);
SGofCPLcommand('b 20 10, move 5 20, b 10 40, h 4, rotx 90')
SGofCPLcommand(
'b 20 10, move 5 20, b 10 40, h 4, roty 90'
);
SGofCPLcommand('b 20 10, move 5 20, b 10 40, h 4, roty 90')
SGofCPLcommand(
'b 20 10, move 5 20, b 10 40, h 4, rotz 90'
);
SGofCPLcommand('b 20 10, move 5 20, b 10 40, h 4, rotz 90')
3.2.4
Manipulating Solids – Melting Separated Solids
SGofCPLcommand(
'c 4, h 2, c 2, h 10 -1'
); VLFLplotlight (1,0.5);
SGofCPLcommand('c 4, h 2, c 2, h 10 -1')
SGofCPLcommand(
'c 4, h 2, c 2, h 10,-1, melt'
); VLFLplotlight (1,0.5);
CPL command "-1" has been ignored
SGofCPLcommand('c 4, h 2, c 2, h 10,-1, melt')
3.2.5
Manipulating Solids – Text Stamp on Surface
SGofCPLcommand(
'c 4, h 2, c 2, h 10,melt, textstamp'
); view(-105,50); camlightTL;
SGofCPLcommand('c 4, h 2, c 2, h 10,melt, textstamp')
SGofCPLcommand(
'c 4, h 2, c 2, h 10,melt, textstamp Yilun-Sun'
); view(-105,50); camlightTL;
SGofCPLcommand('c 4, h 2, c 2, h 10,melt, textstamp Yilun-Sun')
3.2.6
Manipulating Solids – Copy Radial
SGofCPLcommand(
'sph 1, move 2, dupr 7'
);
SGofCPLcommand('sph 1, move 2, dupr 7')
SGofCPLcommand(
'c 1, h 1, move 2, dupr 7'
);
SGofCPLcommand('c 1, h 1, move 2, dupr 7')
3.2.7
Manipulating Solids – Copy with Spatial Distance
SGofCPLcommand(
'sph 10 45 20 30, dups 2 2 2 '
);
SGofCPLcommand('sph 10 45 20 30, dups 2 2 2')
SGofCPLcommand(
'sph 10 45 20 30, dups 2 2 2 5 '
);
SGofCPLcommand('sph 10 45 20 30, dups 2 2 2 5')
3.2.8
Manipulating Solids – Copy on Grid
SGofCPLcommand(
'sph 10 45 20 30, dupg 2 2 2 10'
);
SGofCPLcommand('sph 10 45 20 30, dupg 2 2 2 10')
SGofCPLcommand(
'sph 10 45 20 30, dupg 2 2 2 20'
);
SGofCPLcommand('sph 10 45 20 30, dupg 2 2 2 20')
3.2.9
Manipulating Solids – Hollow Solids
SGofCPLcommand(
'b 10, h 10, hollow 1'
); VLFLplotlight(1,0.2);
SGofCPLcommand('b 10, h 10, hollow 1')
3.2.10 Manipulating Solids – Cutting Solids
SGofCPLcommand(
'b 10, h 10, hollow 1'
);
SGofCPLcommand('b 10, h 10, hollow 1')
SGofCPLcommand(
'b 10, h 10, hollow 1, cutz 8'
);
SGofCPLcommand('b 10, h 10, hollow 1, cutz 8')
SGofCPLcommand(
'b 10, h 10, hollow 1, cutz 3 8'
);
SGofCPLcommand('b 10, h 10, hollow 1, cutz 3 8')
3.2.11
Manipulating Solids – Create a Shell for a Solid
SGofCPLcommand(
'b 10, h 10, shell 1 1'
);
SGofCPLcommand('b 10, h 10, shell 1 1')
SGofCPLcommand(
'b 10, h 10, dup, shell 1 1, add, cutz 5'
); VLFLplotlight(1,0.2);
SGofCPLcommand('b 10, h 10, dup, shell 1 1, add, cutz 5')